import Vue from 'vue'
import App from './App.vue'
import router from './router'
import './plugins/element.js'
import './assets/css/global.css'
import './assets/font_0bs3dh2k8rer/iconfont.css'
import ElementUI from 'element-ui'
import 'element-ui/lib/theme-chalk/index.css'
import axios from 'axios'
import jquery from 'jquery'

Vue.prototype.$jquery = jquery


// 配置axios拦截器 ,在请求之前将token加入到请求header中
axios.interceptors.request.use(config => {
  config.headers.Authorization = sessionStorage.getItem('token')
  return config
})
//将axios 挂载到Vue 原型对象上
Vue.prototype.$http = axios


Vue.use(ElementUI)
//将ElementUI.Message 挂载到Vue 原型对象上
Vue.prototype.$message = ElementUI.Message

Vue.config.productionTip = false

new Vue({
  router,
  render: h => h(App)
}).$mount('#app')
